home *** CD-ROM | disk | FTP | other *** search
/ Amiga Format CD 46 / Amiga Format CD46 (1999-10-20)(Future Publishing)(GB)[!][issue 1999-12].iso / -in_the_mag- / reader_requests / scilab / demos / lmitool / testdscr_lyap < prev    next >
Text File  |  1999-09-16  |  279b  |  18 lines

  1. n=3;
  2. rand('seed',0)
  3. rand('normal')
  4. E=rand(n,1)*rand(1,n)
  5. A=-rand(n,n)-eye
  6. C=rand(n,n);
  7. getf(SCI+'/demos/lmitool/dscr_lyap.sci','c')
  8. [X,Y]=dscr_lyap(E,A,C)
  9. A'*X+Y'*A+C'*C
  10. E'*X-Y'*E
  11. spec(E'*X)
  12.  
  13.  
  14. getf(SCI+'/demos/lmitool/dscr_lyap2.sci','c') 
  15. X=dscr_lyap2(E,A)
  16. E'*X-Y'*E
  17. spec(E'*X)
  18.